package com.weixing.mall.provider.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.weixing.mall.provider.model.domain.Banner;
import com.weixing.mall.provider.model.query.BannerQuery;
import com.weixing.mall.provider.model.vo.cms.BannerVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 轮播图表 Mapper 接口
 * </p>
 *
 * @author Small
 * @since 2019-11-18
 */
public interface BannerMapper extends BaseMapper<Banner> {
    /**
     * @Description 条件查询 <br/>
     * @author gjq
     * @date 2019/7/26 10:17
     * @param bannerQuery
     * @return java.util.List<com.weixing.mall.provider.model.vo.cms.BannerVo>
     */
    IPage<BannerVo> selectListOfPage(@Param("pg") Page page, @Param("qs")BannerQuery bannerQuery);
    /**
     * @Description 批量删除 <br/>
     * @author gjq
     * @date 2019/8/8 16:26
     * @param ids
     * @return void
     */
    void delAll(int[] ids);

    BannerVo getBannerById(long id);

    List<BannerVo> selectListByType(@Param("bannerLoc")int bannerLoc, @Param("bannerType")int bannerType);

}